﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Balance.aspx.cs" Inherits="DQYT.HTDZ.Web.Views.Analysis.balance.Balance" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title></title>
   <link href="../../easyui/themes/default/easyui.css" rel="stylesheet" type="text/css" />
    <link href="../../easyui/themes/icon.css" rel="stylesheet" type="text/css" />   
    <script src="../../easyui/jquery-1.8.0.min.js" type="text/javascript"></script>
    <script src="../../easyui/jquery.easyui.min.js" type="text/javascript"></script>
    <script type="text/javascript" src="js/balance.js" charset='gb2312'></script>
     <script type="text/javascript">
         function CreateTable() {
             var rbl = document.getElementsByName("rbl_balance");
             document.getElementById("txt_advise").value = "";
             for (var i = 0; i < rbl.length; i++) {
                 if (rbl[i].checked && rbl[i].value == "dl_max") {
                     document.getElementById("div_1").style.display = ""; //显示
                     document.getElementById("div_2").style.display = "none"; //隐藏
                     document.getElementById("div_3").style.display = "none"; //隐藏
                 }
                 if (rbl[i].checked && rbl[i].value == "yg_max") {
                     document.getElementById("div_1").style.display = "none";
                     document.getElementById("div_2").style.display = "";
                     document.getElementById("div_3").style.display = "none";
                 }
                 if (rbl[i].checked && rbl[i].value == "yg_avg") {
                     document.getElementById("div_1").style.display = "none";
                     document.getElementById("div_2").style.display = "none";
                     document.getElementById("div_3").style.display = "";
                 }
             }
         }
         //电流最大值平衡度计算
         function on_dlmax_Blur() {
             var val1 = Number(document.getElementById("txt_dlmax_up").value);
             var val2 = Number(document.getElementById("txt_dlmax_down").value);
             var dl_max = val2 / val1;
             dl_max = Math.round((dl_max + 0.001) * Math.pow(10, 2)) / Math.pow(10, 2);
             document.getElementById("txt_dlmax").value = dl_max;
         }
         //有功最大值平衡度计算
         function on_glmax_Blur() {
             var val1 = Number(document.getElementById("txt_glmax_up").value);
             var val2 = Number(document.getElementById("txt_glmax_down").value);
             var gl_max = val2 / val1;
             gl_max = Math.round((gl_max + 0.001) * Math.pow(10, 2)) / Math.pow(10, 2);
             document.getElementById("txt_ygmax").value = gl_max;
         }
         //有功平均值平衡度计算
         function on_glavg_Blur() {
             var val1 = Number(document.getElementById("txt_glavg_up").value);
             var val2 = Number(document.getElementById("txt_glavg_down").value);
             var gl_avg = val2 / val1;
             gl_avg = Math.round((gl_avg + 0.001) * Math.pow(10, 2)) / Math.pow(10, 2);
             document.getElementById("txt_ygavg").value = gl_avg;
         }
    </script>   
    <style type="text/css">
        .style3
        {
            width: 116px;
        }
        .style8
        {
            width: 305px;
        }
        .style9
        {
            height: 30px;
        }
        </style>
     <style type="text/css">
   
     .btn_jisuan{
				width:141px;
				height:57px;
				border:none;
				background:url(/Views/Analysis/images/Balance/jisuan-1.jpg) no-repeat;
			}
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    <table width="100%" height="40" border="0" align="center" cellpadding="0" cellspacing="0" id="__01">
  <tr>
    <td width="10"><img src="images/Balance/6test_01_01.jpg" width="10" height="40" alt=""></td>
    <td width="100%" background="images/Balance/6test_01_02.jpg"><table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td>&nbsp;<span class="STYLE1 STYLE2">抽油机平衡调整</span></td>
        <td align="right"><input type="image" id="backMain" src="images/Balance/backmain.png" alt="Submit"/></td>
      </tr>
    </table></td>
    <td width="10"><img src="images/Balance/6test_01_03.jpg" width="10" height="40" alt=""></td>
  </tr>
</table>
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td width="500" valign="top"><table width="100%" border="0" align="right" cellpadding="00" cellspacing="0">
      <tr>
        <td><table width="100%" border="0" align="center" cellpadding="00" cellspacing="0">
            <tr>
              <td height="40" bgcolor="#F1F2F6"><table width="100%" height="40" border="0" cellpadding="00" cellspacing="0" class="td01">
                  <tr>
                    <td align="center" class="STYLE1"><span class="STYLE5">基本</span><span class="STYLE5">数据</span><span class="STYLE5"></span><span class="STYLE5"></span></td>
                  </tr>
              </table></td>
            </tr>
          </table>
            <table width="100%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#eeeeee"   style="line-height:35px; height:40;padding:5px;">
              <tr>
                <td width="37%" height="160" align="center" bgcolor="#FFFFFF" ><img src="images/Balance/4.jpg" width="167" height="146" border="2"></td>
                <td colspan="3" bgcolor="#FFFFFF" class="style8"><table width="100%" height="160" border="0" cellpadding="0" cellspacing="0">
                    <tr>
                      <td height="40"><table width="96%" border="0" align="right" cellpadding="0" cellspacing="0">
                          <tr>
                            <td width="90">井号：</td>
                            <td><asp:TextBox ID="txt_WELLID" runat="server" Text=""></asp:TextBox></td>
                          </tr>
                      </table></td>
                    </tr>
                    <tr>
                      <td height="40"><table width="96%" border="0" align="right" cellpadding="0" cellspacing="0">
                          <tr>
                            <td width="90">抽油机型号</td>
                            <td><asp:TextBox ID="txt_CYJXH" runat="server"  Text=""></asp:TextBox></td>
                          </tr>
                      </table></td>
                    </tr>
                    <tr>
                      <td height="40"><table width="96%" border="0" align="right" cellpadding="0" cellspacing="0">
                          <tr>
                            <td width="90">电机型号</td>
                            <td><asp:TextBox ID="txt_DJXH" runat="server"  Text=""></asp:TextBox></td>
                          </tr>
                      </table></td>
                    </tr>
                </table></td>
              </tr>

              <tr>
                <td height="40" colspan="4" align="left" bgcolor="#FFFFFF" class="STYLE3"><table width="96%" border="0" cellpadding="0" cellspacing="0"><br />
                   <tr>
                  <td align="left" bgcolor="#FFFFFF" class="STYLE3">抽油机类型</td>
                  <td bgcolor="#FFFFFF" class="STYLE3"><asp:TextBox ID="txt_CYJLX" runat="server"  Text=""></asp:TextBox></td>
                 
                </tr>
                    <tr>
                      <td align="left" bgcolor="#FFFFFF" class="STYLE3">电机额定功率</td>
                <td bgcolor="#FFFFFF" class="STYLE3"><asp:TextBox ID="txt_EDGL" runat="server"  Text=""></asp:TextBox></td>
                                  
                </tr>
                <tr>
                  <td align="left" bgcolor="#FFFFFF" class="STYLE3">电机额定转速</td>
                  <td bgcolor="#FFFFFF" class="STYLE3"><asp:TextBox ID="txt_DJZS" runat="server"  Text=""></asp:TextBox></td>
                 
                </tr>
                <tr>
                  <td align="left" bgcolor="#FFFFFF" class="STYLE3">平衡块重量</td>
                  <td bgcolor="#FFFFFF" class="STYLE3"><asp:TextBox ID="txt_PHKZL" runat="server"  Text="" class="easyui-numberbox" precision="2" validType="number" required="true"></asp:TextBox></td>
                 
              </tr>
              <tr>
                <td align="left" bgcolor="#FFFFFF" class="STYLE3">平衡块数量</td>
                <td bgcolor="#FFFFFF" class="STYLE3"><asp:TextBox ID="txt_PHKSL" runat="server"  Text=""></asp:TextBox></td>
                
              </tr>           
              
             
              <tr>
                <td align="left" bgcolor="#FFFFFF" class="STYLE3">电机拖动方式</td>
                <td bgcolor="#FFFFFF" class="STYLE3"><asp:TextBox ID="txt_TDFS" runat="server"  
                        Text="" style="margin-bottom: 0px"></asp:TextBox></td>
             
              </tr>
             
                </table></td>
              </tr>
              
          </table></td>
      </tr>
    </table></td>
    <td valign="top"><table width="99%" border="0" align="center" cellpadding="00" cellspacing="0">
      <tr>
        <td valign="top"><table width="100%" border="0" align="center" cellpadding="00" cellspacing="0">
            <tr>
              <td height="40" bgcolor="#F1F2F6"><table width="100%" height="40" border="0" cellpadding="00" cellspacing="0" class="td01">
                  <tr>
                    <td align="center" class="STYLE1"><span class="STYLE5"></span><span class="STYLE5">平衡</span><span class="STYLE5">调整</span><span class="STYLE5"></span></td>
                  </tr>
              </table></td>
            </tr>
          </table>
            <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" id="">
             
              <tr>
                <td align="center" valign="top" bgcolor="#FFFFFF" class="STYLE3"><br />           

                  <table width="635" border="0" align="center" cellpadding="0" cellspacing="0">
                      <tr>
                      <td align="right" class="style3">平衡调整方法：</td>
                        <td height="30" class="style3" >
                        <asp:RadioButtonList ID="rbl_balance" 
                                runat="server" Height="16px" Width="476px" 
                                onclick="CreateTable()" RepeatColumns="3" RepeatDirection="Horizontal">
                            <asp:ListItem Value="dl_max" Selected="True">电流最大值平衡度</asp:ListItem>
                            <asp:ListItem Value="yg_max">有功最大值平衡度</asp:ListItem>
                            <asp:ListItem Value="yg_avg">有功平均值平衡度</asp:ListItem>
                            </asp:RadioButtonList>
                          </td>                      
                      </tr>
                      </table>
                  </td>                 
               </tr>

               <tr>              
                 <td align="center" valign="top" bgcolor="#FFFFFF" class="STYLE3"><br />           
                     <div id="div_1" style=" display:"";">
                    <table border="0" align="center" cellpadding="0" cellspacing="0" 
                         style="width: 635px"><tr>                            
                       <td class="style9">电流最大值平衡度</td><td class="style9">
                         <asp:TextBox ID="txt_dlmax" runat="server"  Width="120" Text="" ReadOnly="True"></asp:TextBox>                    
                      </td></tr>
 <tr><td colspan="4"><br /></td></tr> 

                      <tr>                             
                       <td class="style9">上冲程电流最大值</td><td class="style9"><asp:TextBox ID="txt_dlmax_up" runat="server"  Width="120" Text="" onblur="on_dlmax_Blur()" class="easyui-numberbox" precision="2" validType="number" ></asp:TextBox></td>
                       <td class="style9">下冲程电流最大值</td><td class="style9"><asp:TextBox ID="txt_dlmax_down" runat="server" Width="120" Text="" onblur="on_dlmax_Blur()" class="easyui-numberbox" precision="2" validType="number" ></asp:TextBox></td>
                       </tr>
      <tr>         
<td class="style9">上冲程功率因数</td><td class="style9"><asp:TextBox ID="txt_glys_up" runat="server" Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>                    
<td class="style9">下冲程功率因数</td><td class="style9"><asp:TextBox ID="txt_glys_down" runat="server"  Width="120" Text="" class="easyui-numberbox" precision="4" validType="number" ></asp:TextBox></td>
</tr> 
<tr>
<td class="style9">上冲程电机效率</td><td class="style9"><asp:TextBox ID="txt_djxl_one_up" runat="server"  Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>
<td class="style9">下冲程电机效率</td><td class="style9"><asp:TextBox ID="txt_djxl_one_down" runat="server"  Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>
 </tr>  

   <tr><td colspan="4"><br /></td></tr>   
      
  <tr>                                                  
 <td class="style9">单向电压</td><td class="style9"><asp:TextBox ID="txt_dxdy" runat="server" Width="120" Text="" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td>
 <td class="style9">电机输出转速</td><td class="style9"><asp:TextBox ID="txt_djsczs_one" runat="server"  Width="120" Text="" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td> 
 </tr>
   <tr>
   <td class="style9">抽油机冲次</td><td class="style9"><asp:TextBox ID="txt_cyjcc_one" runat="server"  Width="120" Text="" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td>
    <td class="style9">传动效率</td><td class="style9"><asp:TextBox ID="txt_cdxl_one" runat="server"  Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>
</tr>                                     
</table> 
                     </div>

                     <div id="div_2" style="display:none;">
                      <table border="0" align="center" cellpadding="0" cellspacing="0" 
                         style="width: 635px">
                         <tr>                             
                       <td class="style9">有功最大值平衡度</td><td class="style9"><asp:TextBox ID="txt_ygmax" runat="server"  Width="120" Text="" ReadOnly="True"></asp:TextBox>                   
                      </td></tr>
 <tr><td colspan="4"><br /></td></tr> 
                      <tr>                                
                       <td class="style9">上冲程功率最大值</td><td class="style9"><asp:TextBox ID="txt_glmax_up" runat="server"  Width="120" Text="" onblur="on_glmax_Blur()" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td>
                       <td class="style9">下冲程功率最大值</td><td class="style9"><asp:TextBox ID="txt_glmax_down" runat="server"  Width="120" Text="" onblur="on_glmax_Blur()" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td></tr>
      
<tr>
<td class="style9">上冲程电机效率</td><td class="style9"><asp:TextBox ID="txt_djxl_two_up" runat="server" Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>
<td class="style9">下冲程电机效率</td><td class="style9"><asp:TextBox ID="txt_djxl_two_down" runat="server" Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>
</tr>                       
<tr><td colspan="4" ><br /></td></tr> 
  <tr>                                            
 <td class="style9">电机输出转速</td><td class="style9"><asp:TextBox ID="txt_djsczs_two" runat="server" Width="120" Text="" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td> 
<td class="style9">抽油机冲次</td><td class="style9"><asp:TextBox ID="txt_cyjcc_two" runat="server"  Width="120" Text="" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td>                    
 </tr> 
  <tr>                           
    <td class="style9">传动效率</td><td class="style9"><asp:TextBox ID="txt_cdxl_two" runat="server" Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>                    
 </tr>  
 </table>                     
                     </div>
                     <div id="div_3" style="display:none;">
                  <table border="0" align="center" cellpadding="0" cellspacing="0" 
                         style="width: 635px">
                         <tr><td class="style9">有功平均值平衡度</td><td class="style9"><asp:TextBox ID="txt_ygavg" runat="server"  Width="120" Text="" ReadOnly="True"></asp:TextBox>                  
                      </td></tr>
 <tr><td colspan="4"><br /></td></tr> 
          <tr>                                       
                       <td class="style9">上冲程功率平均值</td><td class="style9"><asp:TextBox ID="txt_glavg_up" runat="server"  Width="120" Text="" onblur="on_glavg_Blur()" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td>
                       <td class="style9">下冲程功率平均值</td><td class="style9"><asp:TextBox ID="txt_glavg_down" runat="server"  Width="120" Text="" onblur="on_glavg_Blur()" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td></tr>

<tr>
 <td class="style9">上冲程电机效率</td><td class="style9"><asp:TextBox ID="txt_djxl_three_up" runat="server" Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>
 <td class="style9">下冲程电机效率</td><td class="style9"><asp:TextBox ID="txt_djxl_three_down" runat="server" Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>
 </tr>                    
<tr><td colspan="4"><br /></td></tr> 
    <tr>                           
 <td class="style9">电机输出转速</td><td class="style9"><asp:TextBox ID="txt_djsczs_three" runat="server" Width="120" Text="" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td>
<td class="style9">抽油机冲次</td><td class="style9"><asp:TextBox ID="txt_cyjcc_three" runat="server"  Width="120" Text="" class="easyui-numberbox" precision="2" validType="number"></asp:TextBox></td></tr>
   <tr>                           
 <td class="style9">传动效率</td><td class="style9"><asp:TextBox ID="txt_cdxl_three" runat="server" Width="120" Text="" class="easyui-numberbox" precision="4" validType="number"></asp:TextBox></td>
</tr> 
 </table> </div></td>                
               </tr>
    
              
            </table>
                 </td></tr>

<tr><td><div>
  <asp:ScriptManager ID="ScriptManager1" runat="server">
                  </asp:ScriptManager>
                   <asp:UpdatePanel ID="UpdatePanel1" runat="server">
     <ContentTemplate>
      <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" id="Table1">
        <tr><td align="center">  <br /> <br />                             
                  <asp:Button runat="server" Id="btn_calculate" Text=""  CssClass="btn_jisuan" 
                      onclick="btn_calculate_Click"/> 
               </td></tr>        
        
           <tr> <td align="center" valign="top" bgcolor="#FFFFFF" class="STYLE3"><br />           

                  <table width="600" border="0" align="center" cellpadding="0" cellspacing="0">
                      <tr>                     
                        <td width="14%">调整建议</td>
                      <td width="86%"  align="left">
                           <asp:TextBox ID="txt_advise" runat="server" TextMode="MultiLine" Height="125px" 
                       Width="99%"></asp:TextBox></td>                
                      </tr>
                      </table>
                  </td> </tr>
                  </table>
         </ContentTemplate>
     </asp:UpdatePanel>



</div></td></tr>
             
            
          </table></td>
  </tr>
</table>

<table width="100%" height="47" border="0" align="center" cellpadding="0" cellspacing="0" id="__01">
  <tr>
    <td width="5"><img src="images/Balance/6test_03_01.jpg" width="5" height="47" alt=""></td>
    <td height="47" background="images/Balance/bg2.jpg">&nbsp;</td>
    <td width="5"><img src="images/Balance/6test_03_03.jpg" width="5" height="47" alt=""></td>
  </tr>
</table>

<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p align="right">&nbsp;</p>
<p align="center">&nbsp;</p>
<p align="center">&nbsp;</p>
    </div>
    </form>
</body>
</html>
